Skip to content

windows path surpport - #13

Merged
JinnanDuan merged 6 commits into
openBitFun:mainfrom
Peanut-Puff:main
Jul 8, 2026
Merged

windows path surpport#13
JinnanDuan merged 6 commits into
openBitFun:mainfrom
Peanut-Puff:main

Conversation

@Peanut-Puff

@Peanut-Puff Peanut-Puff commented Jul 8, 2026

Copy link
Copy Markdown

Summary by CodeRabbit

  • New Features
    • Improved Windows compatibility for agent runs, including Windows-aware command handling, script generation, and file path support.
    • Added support for capturing and copying back run logs and config data using the correct OS-specific paths.
  • Chores
    • Expanded ignored files and folders to keep temporary and generated artifacts out of version control.

@coderabbitai

coderabbitai Bot commented Jul 8, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@Peanut-Puff, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 25 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 33e3df69-6bbd-4f29-90bf-71010742ae03

📥 Commits

Reviewing files that changed from the base of the PR and between 2210319 and 50efc62.

📒 Files selected for processing (6)
  • src/harbor/agents/installed/bitfun_cli.py
  • src/harbor/viewer/server.py
  • tests/integration/conftest.py
  • tests/integration/test_windows_hello_world.py
  • tests/unit/agents/installed/test_bitfun_cli.py
  • tests/unit/test_agent_os_compat.py
📝 Walkthrough

Walkthrough

Adds Windows support to the BitfunCli agent by threading an optional environment parameter through path/command helper methods, introducing Windows-specific constants and config/prompt/run-script upload flows, reworking cp-back and run() orchestration to branch by OS, and appending new .gitignore ignore patterns.

Changes

BitfunCli Windows Support

Layer / File(s) Summary
Windows constants, imports, and init defaults
src/harbor/agents/installed/bitfun_cli.py
Adds Path import, Windows-specific binary/log/root path constants, sets SUPPORTS_WINDOWS = True, and updates the default output_patch_path.
Environment-aware path/command helpers
src/harbor/agents/installed/bitfun_cli.py
Refactors internal helpers to accept environment, determine TaskOS, produce Windows-formatted paths/commands, conditionally wrap _exec with set -o pipefail, and adjust run-shell, register-config, and app-config-probe builders for Windows.
Windows prompt/run-script and config capture
src/harbor/agents/installed/bitfun_cli.py
Adds Windows prompt file and .bat run script upload/generation, registers app config at Windows config path, updates cp-back manifest path, and makes final app config capture environment-aware.
cp-back command and run orchestration
src/harbor/agents/installed/bitfun_cli.py
Rewrites _cp_back_command for Windows, branches repo baseline capture and run() orchestration by OS, and passes environment through the final cp-back call.
.gitignore additions
.gitignore
Appends ignore patterns for jobs*/, .bitfun-user-hello-world-bat/, and .tmp/.

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant Runner as run()
  participant Env as BaseEnvironment
  participant Remote as Remote Host

  Runner->>Env: determine TaskOS(environment)
  alt Windows
    Runner->>Remote: register_windows_config()
    Runner->>Remote: upload_windows_prompt()
    Runner->>Remote: upload_windows_run_script()
    Runner->>Remote: build_run_shell(instruction, environment)
    Runner->>Remote: exec run script (no pipefail)
  else Non-Windows
    Runner->>Remote: build_register_config_command()
    Runner->>Remote: capture_repo_baseline()
    Runner->>Remote: exec with set -o pipefail
  end
  Runner->>Remote: cp_back_command(environment)
  Remote-->>Runner: copied logs/config/patch artifacts
Loading
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title is clearly related to the change and points to the added Windows path support, which is a major part of the PR.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

This reverts commit 2210319.
fix(test): skip when windows container is not ready
@JinnanDuan
JinnanDuan merged commit 40294e7 into openBitFun:main Jul 8, 2026
6 checks passed
@coderabbitai coderabbitai Bot mentioned this pull request Jul 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants